// Copyright (c) 2017 Florian Klampfer <https://qwtel.com/>
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program.  If not, see <http://www.gnu.org/licenses/>.

// <<<<< LINK
body {
  /* Prevent side-scrolling on mobile */
  display: block;
  position: relative;
  overflow-x: hidden;
}

hy-push-state, hy-drawer {
  display: block;
  overflow: hidden;
}
// >>>>>

// <<<<< INLINE
@media screen {
  body::before {
    content: '';
    width: .5rem;
    background: var(--border-color);
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
  }

  @media (min-width: $break-point-3) {
    body::before { width: $sidebar-width; }
  }

  @media (min-width: $break-point-dynamic) {
    $r28: ($content-width-5 / 2) + $content-margin-5;
    body::before { width: calc(50% - #{$r28}); }
  }
}

html {
  @media screen and (min-width: $break-point-1) {
    font-size: $root-font-size-medium;
  }

  @media screen and (min-width: $break-point-font-large) {
    font-size: $root-font-size-large;
  }
}
// >>>>>

@media print { html { font-size: $root-font-size-print; } } // link

// <<<<< INLINE
.fade-in {
  animation-duration: 500ms;
  animation-timing-function: ease;
  animation-name: fade-in;
  animation-fill-mode: forwards;
}

@keyframes fade-in {
  from { transform: translateY(-3rem); opacity: 0; }
  50%  { transform: translateY(-3rem); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}
// >>>>>
